Dynamic Programming Algorithms as Products of Weighted Logic Programs
نویسندگان
چکیده
Weighted logic programming, a generalization of bottom-up logic programming, is a successful framework for specifying dynamic programming algorithms. In this setting, proofs correspond to the algorithm’s output space, such as a path through a graph or a grammatical derivation, and are given a weighted score, often interpreted as a probability, that depends on the score of the base axioms used in the proof. The desired output is a function over all possible proofs, such as a sum of scores or an optimal score. We describe the PRODUCT transformation, which can merge two weighted logic programs into a new one. The resulting program optimizes a product of proof scores from the original programs, constituting a scoring function known in machine learning as a “product of experts.” Through the addition of intuitive constraining side conditions, we show that several important dynamic programming algorithms can be derived by applying PRODUCT to weighted logic programs corresponding to simpler weighted logic programs.
منابع مشابه
Products of weighted logic programs
Weighted logic programming, a generalization of bottom-up logic programming, is a wellsuited framework for specifying dynamic programming algorithms. In this setting, proofs correspond to the algorithm’s output space, such as a path through a graph or a grammatical derivation, and are given a real-valued score (often interpreted as a probability) that depends on the real weights of the base axi...
متن کاملProgram transformations for optimization of parsing algorithms and other weighted logic programs
Dynamic programming algorithms in statistical natural language processing can be easily described as weighted logic programs. We give a notation and semantics for such programs. We then describe several source-to-source transformations that affect a program’s efficiency, primarily by rearranging computations for better reuse or by changing the search strategy. We present practical examples of u...
متن کاملLogic programming with costs
We investigate logic programs whose rules are assigned nonnegative real numbers. These numbers are interpreted as the costs of applying rules. There are several ways in which these costs can be interpreted. In the paper, two such interpretations are discussed in detail. They are referred to as no-reusability and reusability interpretations. The former requires that an atom be paid for each time...
متن کاملInference and learning in probabilistic logic programs using weighted Boolean formulas
Probabilistic logic programs are logic programs in which some of the facts are annotated with probabilities. This paper investigates how classical inference and learning tasks known from the graphical model community can be tackled for probabilistic logic programs. Several such tasks such as computing the marginals given evidence and learning from (partial) interpretations have not really been ...
متن کاملInference in Probabilistic Logic Programs using Weighted CNF's
Probabilistic logic programs are logic programs in which some of the facts are annotated with probabilities. Several classical probabilistic inference tasks (such as MAP and computing marginals) have not yet received a lot of attention for this formalism. The contribution of this paper is that we develop efficient inference algorithms for these tasks. This is based on a conversion of the probab...
متن کامل